package edu.zjut.day3;

import java.lang.reflect.Method;

public class MyAdvise implements Advise {
	long beginTime = 0;
	@Override
	public void afterMethod(Method method) {
		System.out.println("end------");
		long endTime = System.currentTimeMillis();
		System.out.println(method.getName()+" running time of "+(beginTime-endTime));
	}

	@Override
	public void beforeMethod(Method method) {
		System.out.println("begin--");;
		beginTime = System.currentTimeMillis();
	}

}
